import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import api from '@/api'

import pop from '@/components/pop.vue'
import placeholder from '@/components/placeholder.vue'

Vue.config.productionTip = false
Vue.use(ElementUI)
Vue.component('pop', pop)
Vue.component('placeholder', placeholder)

// 变量挂载
Vue.use(function (Vue) {
  Vue.prototype.$ev = new Vue()
  Vue.prototype.$api = function () {
    return api(this)
  }
})

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
